package net.wanho.mapper;

import net.wanho.entity.User;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * Author：汤小洋
 * Date：2025-09-17 16:33
 * Description：<描述>
 */
// @Repository
@Mapper
public interface UserMapper {

    void insertUser(User user);

    void updateById(User user);

    void deleteById(int id);

    User selectById(int id);

    List<User> selectAll();

    List<User> selectByUsername(String username);

    User selectByUserNameAndPassword(@Param("userName") String userName,@Param("password") String password);

    User selectByUserNameAndPassword2(User user);

    User selectById2(Integer id);

    User selectById3(Integer id);

    List<User> selectByParams(User user);

    List<User> selectByParams2(User user);

    List<User> selectByIds(List<Integer> ids);

    void insertBatch(List<User> users);
}
